package com.geek.framework.study.validate.domain;



import javax.validation.constraints.NotBlank;

public class GameRole implements Role {

    @NotBlank(message = "职业名称不能为空")
    private String professional;

    @NotBlank(message = "角色昵称不能为空")
    private String nickName;

    @Override
    public String getProfessional() {
        return professional;
    }

    @Override
    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public void setProfessional(String professional) {
        this.professional = professional;
    }

    public static GameRole createDefaultInstance() {
        GameRole gameRole = new GameRole();
        gameRole.setNickName("踩踩");
        gameRole.setProfessional("狂暴者");
        return gameRole;
    }
    public static GameRole createErrorInstance() {
        GameRole gameRole = new GameRole();
        gameRole.setNickName(null);
        gameRole.setProfessional(null);
//        gameRole.setProfessional("狱血魔神");
        return gameRole;
    }
}
